package com.tiger.communal.service.impl;

import java.util.List;

import com.tiger.communal.domain.CommonAgencyEnclosure;
import com.tiger.communal.mapper.CommonAgencyEnclosureMapper;
import com.tiger.communal.service.ICommonAgencyEnclosureService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;


/**
 * 代营公司附件Service业务层处理
 *
 * @author tiger
 * @date 2022-09-13
 */
@Service
public class CommonAgencyEnclosureServiceImpl implements ICommonAgencyEnclosureService
{
    @Autowired
    private CommonAgencyEnclosureMapper commonAgencyEnclosureMapper;

    /**
     * 查询代营公司附件
     *
     * @param id 代营公司附件主键
     * @return 代营公司附件
     */
    @Override
    public CommonAgencyEnclosure selectCommonAgencyEnclosureById(Long id)
    {
        return commonAgencyEnclosureMapper.selectCommonAgencyEnclosureById(id);
    }

    /**
     * 查询代营公司附件列表
     *
     * @param commonAgencyEnclosure 代营公司附件
     * @return 代营公司附件
     */
    @Override
    public List<CommonAgencyEnclosure> selectCommonAgencyEnclosureList(CommonAgencyEnclosure commonAgencyEnclosure)
    {
        return commonAgencyEnclosureMapper.selectCommonAgencyEnclosureList(commonAgencyEnclosure);
    }

    /**
     * 新增代营公司附件
     *
     * @param commonAgencyEnclosure 代营公司附件
     * @return 结果
     */
    @Override
    public int insertCommonAgencyEnclosure(CommonAgencyEnclosure commonAgencyEnclosure)
    {
        return commonAgencyEnclosureMapper.insertCommonAgencyEnclosure(commonAgencyEnclosure);
    }

    /**
     * 修改代营公司附件
     *
     * @param commonAgencyEnclosure 代营公司附件
     * @return 结果
     */
    @Override
    public int updateCommonAgencyEnclosure(CommonAgencyEnclosure commonAgencyEnclosure)
    {
        return commonAgencyEnclosureMapper.updateCommonAgencyEnclosure(commonAgencyEnclosure);
    }

    /**
     * 批量删除代营公司附件
     *
     * @param ids 需要删除的代营公司附件主键
     * @return 结果
     */
    @Override
    public int deleteCommonAgencyEnclosureByIds(Long[] ids)
    {
        return commonAgencyEnclosureMapper.deleteCommonAgencyEnclosureByIds(ids);
    }

    /**
     * 删除代营公司附件信息
     *
     * @param id 代营公司附件主键
     * @return 结果
     */
    @Override
    public int deleteCommonAgencyEnclosureById(Long id)
    {
        return commonAgencyEnclosureMapper.deleteCommonAgencyEnclosureById(id);
    }
}
